package org.go.scheduler;

/**
 * 
 * @author hejie
 *
 */
public class AlwaysScheduleBuilder extends ScheduleBuilder {

	public static ScheduleBuilder repeatSchedule() {
		return new AlwaysScheduleBuilder();
	}

	private long interval;

	private int repeatCount;

	public long getInterval() {
		return interval;
	}

	public int getRepeatCount() {
		return repeatCount;
	}

	public void setInterval(long interval) {
		this.interval = interval;
	}

	public void setRepeatCount(int repeatCount) {
		this.repeatCount = repeatCount;
	}

	public AlwaysScheduleBuilder withIntervalInMilliseconds(long repeatInterval) {
		this.setInterval(repeatInterval);
		return this;
	}

	public AlwaysScheduleBuilder withRepeatCount(@SuppressWarnings("hiding") int repeatCount) {
		this.setRepeatCount(repeatCount);
		return this;
	}
}
